#ifndef _MAIN_H
#define _MAIN_H

#include "STC8G.h"
#include "intrins.h"

#include "uart.h"
#include "tim.h"
#include "pca.h"


#define int8_t signed char
#define int16_t signed short int
#define int32_t signed long
#define uint8_t unsigned char
#define uint16_t unsigned short int
#define uint32_t unsigned long

#define u8  unsigned char
#define u16 unsigned short int
#define u32 unsigned long

sbit LED = P3^2;
sbit M1A = P3^4;
sbit M1B = P3^3;
sbit M2A = P3^5;
sbit M2B = P3^6;

extern uint16_t xdata task1, task2;

void delay_ms(u16 ms);

//     /* exact-width signed integer types */
// typedef   signed          char int8_t;
// typedef   signed short     int int16_t;
// typedef   signed           long int32_t;
// typedef int bool ;

//     /* exact-width unsigned integer types */
// typedef unsigned          char uint8_t;
// typedef unsigned short     int uint16_t;
// typedef unsigned           long uint32_t;

#endif
